From 29a0da72ab98e672ffd2c6348699ccf4278046e6 Mon Sep 17 00:00:00 2001 From: "kaf24@firebug.cl.cam.ac.uk" Date: Thu, 25 May 2006 14:45:40 +0100 Subject: [PATCH] [XEND] Remember cpu-pinning information across guest restarts. Signed-off-by: Qing He --- tools/python/xen/xend/XendDomainInfo.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py index e28f9914a1..0dd3a54eef 100644 --- a/tools/python/xen/xend/XendDomainInfo.py +++ b/tools/python/xen/xend/XendDomainInfo.py @@ -1546,6 +1546,10 @@ class XendDomainInfo: self.configure_bootloader() config = self.sxpr() + if self.infoIsSet('cpus') and len(self.info['cpus']) != 0: + config.append(['cpus', reduce(lambda x, y: str(x) + "," + str(y), + self.info['cpus'])]) + if self.readVm(RESTART_IN_PROGRESS): log.error('Xend failed during restart of domain %d. ' 'Refusing to restart to avoid loops.', -- 2.30.2